@import "../../common/style/var.less";

.number-flip-item {
  position: relative;
  color: @number-flip-item-color;
  display: flex;
  flex-flow: row nowrap;
  justify-content: center;
  align-items: center;

  &__num {
    display: flex;
    flex-flow: column nowrap;
    justify-content: space-between;
    align-items: center;
    &__up {
      background-color: @item-background-color;
      background-repeat: no-repeat;
      overflow: hidden;
    }
    &__down {
      background-color: @item-background-color;
      background-repeat: no-repeat;
      // display: flex;
      // flex-flow: column nowrap;
      // justify-content: flex-start;
      // align-items: center;
      overflow: hidden;
    }
  }
  &__fy {
    position: absolute;
    left: 0;
    top: 0;
    &__front, &__back {
      position: absolute;
      left: 0;
      top: 0;
      background-color: @item-background-color;
      background-repeat: no-repeat;
      overflow: hidden;
      backface-visibility: hidden;
    }
    &__back {
      transform: rotateX(180deg);
      backface-visibility: hidden;
    }
  }
}

//up向下翻页
@keyframes up-fy-down {
  0% {
    transform: rotateX(0deg);
  }
  100% {
    transform: rotateX(180deg);
  }
}

.flip-fy-animation {
  transform-style: preserve-3d;
  animation: up-fy-down @flip-fy-animation-time;
}